local UnitlModule = require("Lua.UnitlModule");

UnitlModule.PrintTimer();
local Object = {};
Object.name = "名字";

--新的思考，为什么不能设为 local
function Object:New()
    local obj = {};
    self.__index = self;
    setmetatable(obj,self);
    return obj;
end

print(Object:New().name);


function  Object:Extend(_className)
    _G[_className] = {};
    self.__index = self;
    setmetatable(_G[_className],self);
    return _G[_className]
end

Object:Extend("NewObj");
NewObj.name = "我是NewObj";
print(NewObj.name);